package cn.edu.scau.cmi.xianjiehua.abstractFactory.factory;

import cn.edu.scau.cmi.xianjiehua.abstractFactory.abstractClass.Insurance;
import cn.edu.scau.cmi.xianjiehua.abstractFactory.company.PICC;
import cn.edu.scau.cmi.xianjiehua.abstractFactory.company.PingAn;

public abstract class CompanyFactory {
	public static CompanyFactory getFactory(String companyName) {
		switch(companyName) {
		case PICC.companyName:
			return new PICC_Factory();
		case PingAn.companyName:
			return new PingAn_Factory();
		}
		return null;
	}
	public abstract Insurance getCarDamage();
	public abstract Insurance getCasualties();
	public abstract Insurance getMulitipleAccidents();
	public abstract Insurance getDriverInjured();
}
